package com.cfilmcloud.learn.controller;

import com.cfilmcloud.learn.domain.Learn;
import com.cfilmcloud.learn.service.LearnService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.PageRequest;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * Created by edz on 2017/7/13.
 */
@RestController
public class LearnController {

    @Autowired
    private LearnService learnService;

    @GetMapping("/learn")
    public List<Learn> doLearn(PageRequest pageRequest) {
        return learnService.findAll();
    }
}
